from base64 import encode
from importlib.resources import path
import os
import pandas as pd
file = "D:/code/note/development/python/yixin-backend/origin/case_record.xlsx"
df = pd.read_excel(file)
print(df)

# 搜索相应的字段
df2 = df[df['中医病名标准']=='便秘']
print("print dict...")
print(df2.to_json(orient="records",force_ascii=False))


# df2 = df[df['中医病名标准'].str.contains('便秘')]



# df2 = pd.DataFrame(("a","b","c"),("1","2","3"))
# print(df2)
# x = df2.to_csv("./test.csv")
# df2.to_excel("./test.xlsx")
# df2.to_json("./test.json")
# print(x)

# print("read excel:")
# print(pd.read_excel("test.xlsx"))
# print(pd.read_excel("case_record.xlsx"))
# print("read absolute path")
# print(pd.read_excel("D:/code/note/case_record.xlsx"))


